using System;
using System.Collections;

namespace Com.CMS263.PO
{
	#region Product

	/// <summary>
	/// Product object for NHibernate mapped table 'Product'.
	/// </summary>
	public class Product
	{
		#region Member Variables
		
		protected int _id;
		protected string _productNum;
		protected string _productDescription;
		protected string _title;
		protected string _productImg;
		protected string _styleIds;
		protected int _productType;
		protected bool _isPub;
		protected int _sortId;
        protected string _salePrice;

		#endregion

		#region Constructors

		public Product() { }

		public Product( string productNum, string productDescription, string title, string productImg, string styleIds, int productType, bool isPub, int sortId,string salePrice)
		{
			this._productNum = productNum;
			this._productDescription = productDescription;
			this._title = title;
			this._productImg = productImg;
			this._styleIds = styleIds;
			this._productType = productType;
			this._isPub = isPub;
			this._sortId = sortId;
            this._salePrice = salePrice;
		}

		#endregion

		#region Public Properties

		public virtual int Id
		{
			get {return _id;}
			set {_id = value;}
		}

		public  virtual string ProductNum
		{
			get { return _productNum; }
			set
			{
				if ( value != null && value.Length > 50)
					throw new ArgumentOutOfRangeException("Invalid value for ProductNum", value, value.ToString());
				_productNum = value;
			}
		}
        public virtual string SalePrice
        {
            get { return _salePrice; }
            set
            {
                if (value != null && value.Length > 50)
                    throw new ArgumentOutOfRangeException("Invalid value for SalePrice", value, value.ToString());
                _salePrice = value;
            }
        }

		public  virtual string ProductDescription
		{
			get { return _productDescription; }
			set
			{
				if ( value != null && value.Length > 4000)
					throw new ArgumentOutOfRangeException("Invalid value for ProductDescription", value, value.ToString());
				_productDescription = value;
			}
		}

		public  virtual string Title
		{
			get { return _title; }
			set
			{
				if ( value != null && value.Length > 200)
					throw new ArgumentOutOfRangeException("Invalid value for Title", value, value.ToString());
				_title = value;
			}
		}

		public  virtual string ProductImg
		{
			get { return _productImg; }
			set
			{
				if ( value != null && value.Length > 4000)
					throw new ArgumentOutOfRangeException("Invalid value for ProductImg", value, value.ToString());
				_productImg = value;
			}
		}

		public  virtual string StyleIds
		{
			get { return _styleIds; }
			set
			{
				if ( value != null && value.Length > 50)
					throw new ArgumentOutOfRangeException("Invalid value for StyleIds", value, value.ToString());
				_styleIds = value;
			}
		}

		public  virtual int ProductType
		{
			get { return _productType; }
			set { _productType = value; }
		}

		public  virtual bool IsPub
		{
			get { return _isPub; }
			set { _isPub = value; }
		}

		public  virtual int SortId
		{
			get { return _sortId; }
			set { _sortId = value; }
		}

		

		#endregion
	}
	#endregion
}